﻿CREATE TABLE [dbo].[ConsultationItem] (
    [Id]             INT            IDENTITY (1, 1) NOT NULL,
    [ConsultationId] INT            NOT NULL,
    [BillId]         INT            NULL,
    [Type]           INT            NOT NULL,
    [Content]        NVARCHAR (500) NULL,
    [AddDt]          DATETIME       NULL,
    [Status]         INT            NULL,
    [UpdateDt]       DATETIME       NULL,
    [DeleteDt]       DATETIME       NULL,
    [DeleteStatus]   INT            NULL,
    CONSTRAINT [PK__Consulta__3214EC0703BB8E22] PRIMARY KEY CLUSTERED ([Id] ASC)
);


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'主键', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'Id';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'咨询id', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'ConsultationId';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'账单ID', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'BillId';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'咨询类型1-咨询 2-答复', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'Type';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'内容', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'Content';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'创建时间', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'AddDt';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'状态1正常2-删除', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'Status';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'更新时间', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'UpdateDt';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'删除时间', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'DeleteDt';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'删除状态', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'ConsultationItem', @level2type = N'COLUMN', @level2name = N'DeleteStatus';

